import { http } from "@/utils/http";

type ResultTable = {
  total?: number;
  data?: Array<any>;
};

//查询碳交易列表
export const quotalistTrade = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/listTrade`, {
    data
  });
};

//查询碳交易详情
export const quotadetailTrade = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/detailTrade`, {
    data
  });
};

//删除碳交易
export const quotadeleteTrade = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/deleteTrade`, {
    data
  });
};

//新增/更新碳资产
export const quotaupdateTrade = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/updateTrade`, {
    data
  });
};
